package itcz.example.pattern.structure_type.decorator;

/**
 * @ClassName: Client
 * @Author: ITCZ
 * @Date: 2025-04-23
 * @Description:
 */
public class Client {
    public static void main(String[] args) {
        FastFood fastFood = new FriedRice();
        System.out.println("food desc:" + fastFood.getDesc() + ",food price:" + fastFood.cost());

        System.out.println("========================");

        fastFood =new Egg(fastFood);
        System.out.println("food desc:" + fastFood.getDesc() + ",food price:" + fastFood.cost());

        fastFood = new Bacon(fastFood);
        System.out.println("food desc:" + fastFood.getDesc() + ",food price:" + fastFood.cost());
    }
}
